<?php
/**
 * Author: Administrator
 * Date: 2022/7/17 1:32
 */

namespace DesignPatterns\Structural\Adapter;


class EBookAdapter implements PaperBookInterface
{
    protected $ebook;

    public function __construct(EBookInterface $eBook)
    {
        $this->ebook = $eBook;
    }

    public function turnPage()
    {
        return $this->ebook->pressNext();
    }

    public function open()
    {
        return $this->ebook->pressStart();
    }
}